package com.fhz.circle.register.view;

import androidx.lifecycle.LiveData;
import androidx.lifecycle.MutableLiveData;

import com.fhz.circle.register.data.User;
import com.fhz.core_lib.mvvm.BaseViewModel;

/**
 * 时间:11/14/21
 *
 * @author msfeng
 * 简述: ViewModel
 */
public class RegisterViewModel extends BaseViewModel<RegisterRepository> {

    private MutableLiveData<User> userMutableLiveData = new MutableLiveData<>();

    public RegisterViewModel(RegisterRepository repository) {
        super(repository);
    }

    public MutableLiveData<User> getUserMutableLiveData() {
        return userMutableLiveData;
    }

    //注册
    public LiveData<User> registerUser(User user){
        return repositroy.register(user);
    }
}
